// part1:C15:15.15:Bulk_quote.h
// class Bulk_quote.
// debug function.
#ifdef BULK_QUOTE_H__
#define BULK_QUOTE_H__
#include "Disc_quote.h" 
#include <iostream>
class Bulk_quote : public Disc_quote
{
public:
    Bulk_quote(const string &book = "", double sales_price = 0,
        size_t qty = 0, double disc_rate = 0):
      Disc_quote(book, sales_price, qty, disc_rate){}
    double net_price(size_t cnt) const
    {
        if (cnt >= quantity) 
        {
            return cnt * (1 - discount) * price;
        }
        else
        {
            return cnt * price;
        }
    }

    // virtual void debug()
    // {
    //     Quote::debug();
    //     cout << "min_qty = " << min_qty << " discount = " <<
    //       discount << endl;
    // }
private:
    //size_t min_qty;
    //double discount;
};
#endif
